package com.lemobar.pay.model.wxpay.request;

import lombok.Data;
import org.simpleframework.xml.Element;
import org.simpleframework.xml.Root;


/**
 * 查询订单 请求对象
 * JSAPI https://pay.weixin.qq.com/wiki/doc/api/jsapi.php?chapter=9_2
 * APP支付 https://pay.weixin.qq.com/wiki/doc/api/app/app.php?chapter=9_2&index=4
 * 小程序支付 https://pay.weixin.qq.com/wiki/doc/api/wxa/wxa_api.php?chapter=9_2
 * 付款码支付 https://pay.weixin.qq.com/wiki/doc/api/wxa/wxa_api.php?chapter=9_2
 */
@Data
@Root(name = "xml", strict = false)
public class WxPayQueryRequest {

    /**
     * 公众账号ID
     */
    @Element(name = "appid")
    private String appid;

    /**
     * 商户号
     */
    @Element(name = "mch_id")
    private String mchId;

    /**
     * 微信的订单号
     * 建议优先使用
     */
    @Element(name = "transaction_id", required = false)
    private String transactionId;

    /**
     * 商户订单号
     */
    @Element(name = "out_trade_no", required = false)
    private String outTradeNo;

    /**
     * 随机字符串
     * 不长于32位
     */
    @Element(name = "nonce_str")
    private String nonceStr;

    /**
     * 签名
     */
    @Element(name = "sign")
    private String sign;

    /**
     * 签名类型
     * 目前支持HMAC-SHA256和MD5，默认为MD5
     */
    @Element(name = "sign_type", required = false)
    private String signType;
}
